<template>
  <a-config-provider :locale="zhCN">
    <a-layout>
      <a-layout-sider class="wd-sider-left">
        <i-menu :menuList="menuAntdList"></i-menu>
      </a-layout-sider>
      <a-layout-content class="wd-main">
        <router-view />
      </a-layout-content>
    </a-layout>
  </a-config-provider>
</template>
<script lang="ts">
import zhCN from 'ant-design-vue/es/locale/zh_CN'
import { defineComponent } from 'vue'
import { useRouter } from 'vue-router'
import { ConfigProvider } from 'ant-design-vue'
import { IMenu } from 'wd-platform-library'
export default defineComponent({
    name: 'auth_app',
    components: {
        IMenu,
        'a-config-provider': ConfigProvider
    },
    setup () {
        const router = useRouter()
        // eslint-disable-next-line no-return-assign
        const menuAntdList = router.options.routes
        return {
            router,
            menuAntdList,
            zhCN
        }
    }
})

</script>
<style lang="scss" scoped>
.wd-main {
  background: $bg-base;
  padding: 12px;
  overflow: hidden;
}

.wd-sider-left {
  width: 160px !important;
  flex: 0 0 160px !important;
  max-width: 160px !important;
  min-width: 160px !important;
}
</style>
